package dudghk;

public class J01Retangle_쌤 {
	//사각형 면적, 둘레 계산하는 프로그램
		//입력값:가로,세로,색상
		
		public static void main(String[] args){
			//1. 변수선언 및 초기화
		double	width = 1.0;     //실수 double
		double	height = 1.0;   
		String color = "white";    // 문자열 String
		double getArea;
		double getPerimter;
		
		
		//2.계산 및 연산
		 getArea = width*height;
		 getPerimter= (width+height)*2;
		
		//3. 결과출력
		System.out.println(width);
		System.out.println(height);
		System.out.println(color);
		System.out.println(getArea);
		System.out.println(getPerimter);
		
		//시험값1 : 4, 40, red
		width = 4;
		height = 40;
		color = "red";
		
		getArea = width*height;
		getPerimter= (width+height)*2;
		
		System.out.println("시험값1");
		System.out.println(width);
		System.out.println(height);
		System.out.println(color);
		System.out.println(getArea);
		System.out.println(getPerimter);
		
		//시험값2 : 3.5, .5.9, orange
		
		width = 3.5;
		height = 35.9;
		color = "orange";
		
		getArea = width*height;
		getPerimter = (width+height)*2;
		
		System.out.println("시험값2");
		System.out.println(width);
		System.out.println(height);
		System.out.println(color);
		System.out.println(getArea);
		System.out.println(getPerimter);
	
		}
}
